#define  _CRT_SECURE_NO_WARNINGS

#include<stdio.h>
int main()
{
    int n = 0;
    scanf("%d", &n);
    int arr[100] = { 0 };
    int i = 1, j = 0;
    arr[0] = n;
    while (1)
    {
        arr[i] = arr[i - 1] / 2;
        if (arr[i] == 1)
            break;
        i++;
    }
    for (j = 0; j < i + 1; j++)
        printf("%d ", arr[j]);
    return 0;
}